package com.lynn.blog.entity;

import com.mybatisflex.annotation.Id;
import com.mybatisflex.annotation.KeyType;
import com.mybatisflex.annotation.Table;
import java.io.Serializable;
import java.sql.Timestamp;

import java.io.Serial;

import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 *  实体类。
 *
 * @author root
 * @since 2024-07-15
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
@Table("post")
public class Post implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    @Id(keyType = KeyType.Auto)
    private Integer postId;

    private String title;

    private String content;

    private Long userId;

    private Timestamp created;

    private Timestamp lastModified;

    /**
     * 逻辑删除标志, 0-未删除, 1-已删除
     */
    private Boolean isDeleted;

}
